import { defineStore } from "pinia";

interface IState {
    socketTimeout: number;
    status: number;
}

export const useNet = defineStore("net", {
    state: (): IState => ({
        socketTimeout: 500,
        status: 0
    }),

    getters: {},
    actions: {
        changeSocketTimeout(val: number) {
            this.socketTimeout = val;
        },
        changeStatus(val: number) {
            this.status = val;
            // console.log("this.status", this.status);
        }
    }
});
